package lab02;

public class Zelos implements Boss {
    private String name;
    private int Hp;
    public Zelos() {
    }

    public Zelos(String name, int Hp) {
        this.name = name;
        this.Hp = Hp;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getHp() {
        return Hp;
    }

    public void setHp(int hp) {
        Hp = hp;
    }

    @Override
    public void attack() {
        System.out.println("Zelos发动了攻击");
    }

    @Override
    public void move() {
        System.out.println("Zelos进行了飞行移动");
    }

    @Override
    public void addhp() {
        while (Hp > 0) {
            if (Hp >= 10) {
                System.out.println("受到攻击-25");
                Hp = Hp - 25;
                System.out.println("生命剩余值:"+Hp);

            }
            if (Hp > 0 && Hp < 10) {
                Hp += 30;
                System.out.println("生命低于10  +30");
                System.out.println("生命剩余值:"+Hp);
            }
            if (Hp <= 30) {
                Hp-=25;
                System.out.println("受到攻击-25");
                System.out.println("生命剩余值:"+Hp);
                System.out.println("很遗憾您已死亡");

                break;
            }
        }
    }
}
